package com.sxjh.controller.pub;

import com.sxjh.common.Result;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.time.LocalDateTime;

@RestController
@Api(tags = "时间控制器")
@RequestMapping("/api/date")
public class DateController {

  @ApiOperation("获取当前时间")
  @GetMapping
  Result<LocalDateTime> localDateTimeResult() {
    return Result.ok(LocalDateTime.now());
  }

}
